<form id="pull-request-edit-modal"
    class="tlp-modal"
    role="dialog"
    aria-labelledby="pull-request-edit-modal-title"
    ng-submit="edit_modal.save()"
>
    <div class="tlp-modal-header">
        <h1 id="pull-request-edit-modal-title" class="tlp-modal-title">
            <i class="tlp-modal-title-icon fa fa-pencil" aria-hidden="true"></i>
            <span translate>Edit message</span>
        </h1>
        <div class="tlp-modal-close" data-dismiss="modal" aria-label="{{ 'Close' | translate }}">
            ×
        </div>
    </div>
    <div class="tlp-modal-body">
        <div class="tlp-form-element">
            <label class="tlp-label" for="pullrequest-title">
                {{ 'Title' | translate }}
                <i class="fa fa-asterisk"></i>
            </label>
            <input id="pullrequest-title"
                   class="tlp-input"
                   type="text"
                   ng-model="edit_modal.raw_title"
                   placeholder="{{ 'Title' | translate }}"
                   required
            >
        </div>

        <div class="tlp-form-element">
            <label class="tlp-label" for="pullrequest-description" translate>Description</label>
            <textarea id="pullrequest-description"
                      class="tlp-textarea"
                      rows="15"
                      ng-model="edit_modal.raw_description"
                      placeholder="{{ 'Description' | translate }}"
            ></textarea>
        </div>
    </div>
    <div class="tlp-modal-footer">
        <button type="button" class="tlp-button-primary tlp-button-outline tlp-modal-action" data-dismiss="modal">
            <span translate>Cancel</span>
        </button>
        <button type="submit"
            class="tlp-button-primary tlp-modal-action"
            ng-disabled="edit_modal.is_saving"
        >
            <i class="tlp-button-icon fa"
               ng-class="{'fa-save': ! edit_modal.is_saving, 'fa-spinner fa-spin': edit_modal.is_saving}"
            ></i>
            <span translate>Save</span>
        </button>
    </div>
</form>
